﻿<Window x:Class="UserNotificationDemo.View.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        
        xmlns:view ="clr-namespace:UserNotification.View;assembly=UserNotification"
        
        Title="Notification generator" Height="400" Width="300">
  <Grid>
    <Grid.RowDefinitions>
      <RowDefinition Height="Auto" />
      <RowDefinition Height="*" />
    </Grid.RowDefinitions>
    <StackPanel Grid.Row="0">
      <Button Width="200" Height="30" Margin="4" Command="{Binding Notification1}">Add notification</Button>
      <Button Width="200" Height="30" Margin="4" Command="{Binding Notification2}">Add notification</Button>
      <Button Width="200" Height="30" Margin="4" Command="{Binding Notification3}">Add notification</Button>
      <Button Width="200" Height="30" Margin="4" Command="{Binding Notification4}">Add notification</Button>
    </StackPanel>

    <Grid Grid.Row="1" DataContext="{Binding NotifyableContent}">
      <Grid.ColumnDefinitions>
        <ColumnDefinition Width="*" />
        <ColumnDefinition Width="Auto" />
      </Grid.ColumnDefinitions>

      <view:NotifyableContentControl Notification="{Binding Notification}" Grid.Column="0" Margin="3">
        <ListBox HorizontalAlignment="Stretch"
               VerticalAlignment="Stretch"
               ItemsSource="{Binding ItemCollection}"
               >
        </ListBox>
      </view:NotifyableContentControl>

      <StackPanel Grid.Column="1">
        <Button Content="Notify" Command="{Binding ShowNotificationCommand}" Margin="3" />
      </StackPanel>
    </Grid>
  </Grid>
</Window>
